package com.qingcloud.adminbackend.enums;

/**
 * 网格化监测点种类枚举
 */
public enum GridStationCategoryEnum {

    ONE(1010, "微站-单传感器"),
    SIX(6010, "微站-６传感器"),
    TVOC(6020, "微站-TVOC"),
    NOISE(6030, "微站-噪声"),
    TN(6040, "微站-TVOC噪声"),
    SIX_MONITOR(2, "六参数便携式"),
    TVOC_MONITOR(3, "六参数+TVOC便携式"),
    KH(98, "考核站"),
    PC(99, "爬虫站"),
    YC(101, "扬尘站");

    public int code;

    public String name;

    GridStationCategoryEnum(int code, String name) {
        this.code = code;
        this.name = name;
    }

    public static String getNameByCode(int code) {
        GridStationCategoryEnum[] uss = values();
        for (GridStationCategoryEnum us : uss) {
            if (us.code == code) {
                return us.name;
            }
        }
        return null;
    }
}
